package net.mfjassociates.finance.domain.mfjfin_newdb;

import java.math.BigDecimal;
import java.util.Date;
import javax.persistence.Column;
import javax.persistence.Embeddable;
import javax.persistence.Temporal;
import javax.persistence.TemporalType;
import org.springframework.format.annotation.DateTimeFormat;
import org.springframework.roo.addon.jpa.identifier.RooIdentifier;

@Embeddable
@RooIdentifier(dbManaged = false)
public final class PaymentsPK {

	@Column(name = "PaymentID", nullable = false)
    private Integer paymentId;

	@Column(name = "ProjectID", nullable = false)
    private Integer projectId;

	@Column(name = "PaymentAmount", nullable = false, precision = 19, scale = 4)
    private BigDecimal paymentAmount;

	@Column(name = "PaymentDate", nullable = false)
    @Temporal(TemporalType.DATE)
    @DateTimeFormat(style = "M-")
    private Date paymentDate;

	@Column(name = "CreditCardNumber", nullable = false, length = 30)
    private String creditCardNumber;

	@Column(name = "CardholdersName", nullable = false, length = 50)
    private String cardholdersName;

	@Column(name = "CreditCardExpDate", nullable = false)
    @Temporal(TemporalType.DATE)
    @DateTimeFormat(style = "M-")
    private Date creditCardExpDate;

	@Column(name = "PaymentMethodID", nullable = false)
    private Integer paymentMethodId;

	public PaymentsPK(Integer paymentId, Integer projectId, BigDecimal paymentAmount, Date paymentDate, String creditCardNumber, String cardholdersName, Date creditCardExpDate, Integer paymentMethodId) {
        super();
        this.paymentId = paymentId;
        this.projectId = projectId;
        this.paymentAmount = paymentAmount;
        this.paymentDate = paymentDate;
        this.creditCardNumber = creditCardNumber;
        this.cardholdersName = cardholdersName;
        this.creditCardExpDate = creditCardExpDate;
        this.paymentMethodId = paymentMethodId;
    }

	private PaymentsPK() {
        super();
    }

	public Integer getPaymentId() {
        return paymentId;
    }

	public Integer getProjectId() {
        return projectId;
    }

	public BigDecimal getPaymentAmount() {
        return paymentAmount;
    }

	public Date getPaymentDate() {
        return paymentDate;
    }

	public String getCreditCardNumber() {
        return creditCardNumber;
    }

	public String getCardholdersName() {
        return cardholdersName;
    }

	public Date getCreditCardExpDate() {
        return creditCardExpDate;
    }

	public Integer getPaymentMethodId() {
        return paymentMethodId;
    }
}
